package com.mkyong.soa.server;

import java.rmi.RemoteException;
import java.rmi.registry.LocateRegistry;
import java.rmi.registry.Registry;
import java.rmi.server.UnicastRemoteObject;

public class Server {
	public static void main(String[] args) throws RemoteException {
		int port = 9527;
		String name = "businessDemo";
		Business biz = new BussinessImpl();
		UnicastRemoteObject.exportObject(biz, port);
		
		Registry registry = LocateRegistry.createRegistry(1099);
		registry.rebind(name, biz);
	}
}	
